User-defined substitution lists

 

Let us first open the query, select the last parameter and click on the Edit… button. This will open the previously described MDX query parameter dialog with all fields set to the currently defined values. Now, change the substitution mode to Replace this instance from the user-defined list of values (substitution list), and the new (additional) Substitution tab on this dialog becomes visible:

 

 

Please note that the Accept button is disabled now, because we have not defined the substitution list yet. Let us now open the Substitution tab:

 

 

Right now, the substitution list is empty, but we can add as many items as we need by clicking on the Add button. Every click opens a new table row and you must manually type two (2) values:

 

1.       Displayed value, and

2.       Substitution value

 

Displayed value will be presented to the end user and you should type some user-friendly, easy to understand string.

Substitution value will be used in the replacement process. When the end-user selects some item from this list, the default parameter value will be replaced with the substitution value of the selected item.

Let us define three (3) items in this example:

 

Displayed value

Substitution value

Profit

[Measures].[Profit]

Store Cost

[Measures].[Store Cost]

Sales Average

[Measures].[Sales Average]

 

The following screen shows the three parameters already entered into the table:

 

 

We can now accept the predefined list by clicking on the Accept button. This will close the dialog and the change is automatically reflected in the MDX queries dialog:

 

More:

Changing an item from the user-defined list